<?php
echo "<h4>Partie pratique</h4>";


// Affichage de la note
/*
if ($proprietaire != claro_get_current_user_id())
{
	echo '<strong>Note pratique : </strong><span id="notePratique">';

	$listeCompetencesTmp = chercheReferentielC2i($C2i,'pratique');
	foreach ($listeCompetencesTmp as $competence)
	{
		if ($competence['sous_ref'] != 0)
		continue;

		if ($competence['epreuve_speciale'] == 'theorique')
		{
			continue;
		}
		$listeCompetencesPratique[$competence['competence']] = $competence['note'];
	}


	$sql = "SELECT competence,note as resultat
		FROM cl_C2iResultats
		WHERE userId = ".$proprietaire."
		AND epreuve = 'pratique'
		AND c2i = '".$C2i."'
		AND alinea = 0";
	$notesEtudiant = claro_sql_query_fetch_all_rows($sql);



	$resultatPratique = 0;
	$eliminatoire = array();

	if ($notesEtudiant)
	{
		foreach ($notesEtudiant as $notes)
		{
			$resultat = round(($notes['resultat']/$listeCompetencesPratique[$notes['competence']])*$coeffPratique['N1'][$notes['competence']],2);
			$resultatPratique += $resultat;

			if ($resultat <= $coeffPratique[$C2i][$notes['competence']]*$noteEliminatoire[$C2i])
			{
				$eliminatoire[] = $notes['competence'];
			}
		}
	}

	unset ($listeComp);
	if ($eliminatoire)
	{
		for($i=0;$i<count($eliminatoire);$i++)
		{
			$listeComp .= $eliminatoire[$i]." ";
		}

		$eliminatoire = '<br><span style="color:red"> AJOURNE note eliminatoire : '.$listeComp.'</span>';
	}

	echo $resultatPratique.'/'.$coeffNotePratique[$C2i].' '.$eliminatoire.'</span>';
}
*/


// Gestion des fichiers
if ($gestionDoc==true && $proprietaire == claro_get_current_user_id())
{
	echo '<div id="gestionDocsHeader"><a href="'.$_SERVER['REQUEST_URI'].'&action=gestionDocuments#gestionDocsHeader"><img src="img/documents.png"> Gestion de mes documents</a></div><div>';


	/*
	echo '<table id="gestionDocsHeader">
		<tr>
		  <th><img src="img/documents.png"> Gestion de mes documents</th>
		  <th class="slideUpDown"><a href="'.$_SERVER['REQUEST_URI'].'&action=gestionDocuments#gestionDocsHeader"><img src="' . get_path('imgRepositoryWeb') . 'down.gif" id="slider"></a></th></tr><tr><td colspan=2>';
	*/

	// Traitement upload des documents
	$feedbackUpload = traitementUploadDocument($proprietaire);

	echo afficherGestionDocuments($proprietaire);

	echo "</div>";

	$gestionDoc = true;
}

if ($C2i == 'N2MD')
$grilleDefaut = "4";

if ($C2i == 'N2MS')
$grilleDefaut = "6";

if ($C2i == 'N2MEAD')
$grilleDefaut = "7";

	//include(get_path('rootSys').'stats/lib/conf.php');

include('C2IPRAT/evaluation.php');
?>
